#include <stdio.h>
#include <unistd.h>
#include <string.h>
#include <stdlib.h>
int main(int argc,char* argv[],char *env[])
{
 // printf("hello");
  if(argc!=2)
  {
    printf("can not execute!it must be cmd + option(s)\n");
    exit(-1);
  }
  printf("获取环境变量:my_val:%s\n",getenv("my_val"));
  if(strcmp(argv[1],"-a")==0)
  {
    printf("good job\n");
  }
  else if(strcmp(argv[1],"-b")==0)
  {
    printf("work well\n");
  }
  else
  {
    printf("defalut\n");
  }
  return 0;
}
